#!/usr/bin/python
# -*- coding: utf-8 -*-

class AreaConstraint:

    def __init__ (self, allowed_areas, forbidden_areas):

        self._allowed_areas = allowed_areas
        self._forbidden_areas = forbidden_areas
        
    def __str__ (self):

        aux = '[Allowed areas: '
        c = 0

        for i in self._allowed_areas:
            aux += i
            c += 1
            if c < len(self._allowed_areas):
                aux += '; '

        aux += ']'

        aux += '[Forbidden areas: '
        c = 0

        for i in self._forbidden_areas:
            aux += i
            c += 1
            if c < len(self._forbidden_areas):
                aux += '; '

        aux += ']'

        return aux
